Gimpel Home Page
Sample Program
On-Line Demonstrations of FlexeLint and PC-lint (aka FlexeLint for Windows)

Bug of the Month for February 2003

Bug of the Month Samples

The programmer expected the first string printed to be "original" but was surprised when the second also printed "original". He expected argument passing to invoke a copy constructor that would result in a "copy". Where did the programmer go wrong?

Modify this example, if desired, and then hit the Analyse Code button

Run FlexeLint on Bug of the Month Samples
Home | Examples | Contact | Order

PC-lint and FlexeLint are trademarks of Gimpel Software
Copyright © 2009, Gimpel Software

Viewable With Any Browser